Skip to content

feat(contracts): publish portable web interactions v1 - #5

Merged
BunsDev merged 12 commits into
mainfrom
feat/portable-web-interactions-v1
Aug 31, 2026
Merged

feat(contracts): publish portable web interactions v1#5
BunsDev merged 12 commits into
mainfrom
feat/portable-web-interactions-v1

Conversation

@BunsDev

@BunsDev BunsDev commented Aug 31, 2026

Copy link
Copy Markdown
Member

Objective

Publish the framework-neutral interaction, accessibility, failure, and progressive-enhancement contract required by OpenCoven public web surfaces without forcing React, Tailwind, Base UI, or the UI specimen application onto static consumers.

What changed

  • adds a stable opencoven.ui-web-interactions/v1 machine contract with 14 primitives:
    • action, disclosure, global/mobile navigation, tabs, tooltip;
    • status, progress, copy, download, and theme controls;
    • dialog, guided proof, and error surface;
  • defines native semantics, stable data-oc-* conformance hooks, shared states, keyboard maps, focus entry/containment/return, 44×44 targets, no-JavaScript behavior, failure/recovery, reduced motion, forced colors, and forbidden misuse;
  • adds 24 shared mutation-guarded vectors covering JavaScript and no-JavaScript, keyboard-only use, 320 px, 200% zoom/reflow, reduced motion, forced colors, target size, focus restoration, async feedback, download fallback, and unavailable-state honesty;
  • adds a plain HTML/JavaScript native-first reference fixture rather than a private React implementation;
  • extends the existing architecture verifier to validate the portable schema, semver, primitives, states, selectors, vectors, fixture, and download/failure boundaries while preserving the current package contracts;
  • documents ownership, conformance result vocabulary, versioning, and downstream pinning.

Ownership boundary

OpenCoven/ui owns reusable interaction semantics and test vectors. Visual identity/token values remain owned by OpenCoven/brand. Product state, authority, protocol, and runtime behavior remain owned by their product/protocol repositories.

Ordinary site navigation is not an application menu. Mobile navigation is not a modal. Tabs do not perform remote mutation. Tooltips contain no essential or interactive content. Progress is measured, not decorative. Page JavaScript never owns installer bytes. Dialogs are reserved for true modal tasks. Guided proof remains complete without canvas, WebGL, drag, or motion.

Verification

pnpm install --frozen-lockfile
pnpm check

The contract gate now verifies the existing UI architecture plus 14 portable primitives and at least 24 shared vectors. Unsupported platform/capability coverage must be reported with a reason and is never counted as pass.

Downstream handoff

After merge, coven-landing will pin the immutable merge revision, vendor only the exported contract/vector artifacts with provenance hashes, expose the stable hooks, and execute the applicable shared vectors in its static Astro implementation.

Closes #4.
Refs OpenCoven/coven-landing#73, OpenCoven/coven-landing#81, and OpenCoven/coven-landing#82.

Copilot AI lite review requested due to automatic review settings August 31, 2026 02:34
@vercel

vercel Bot commented Aug 31, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
opencoven-ui Ready Ready Preview Aug 31, 2026 2:39am
ui Error Error Aug 31, 2026 2:39am

Request Review

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces a framework-neutral “portable web interactions” contract (v1) plus a shared conformance vector suite and a plain HTML/JS reference fixture, and extends the existing contract verifier to enforce the new artifacts without requiring the React/Tailwind specimen app.

Changes:

  • Added opencoven.ui-web-interactions/v1 contract JSON describing 14 primitives, global laws, states, and conformance hooks.
  • Added opencoven.ui-test-vectors/v1 shared conformance vectors (mutation-guarded) and a native-first reference HTML/JS fixture.
  • Extended scripts/verify-contracts.mjs and ESLint config to validate/enable the new portable artifacts.

Reviewed changes

Copilot reviewed 9 out of 10 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
scripts/verify-contracts.mjs Adds portable contract/vector/fixture/doc validation to the existing architecture contract gate.
eslint.config.js Adds browser globals for the plain JS fixture linting context.
contracts/web-interactions.v1.json New portable interaction/semantics contract (v1).
contracts/test-vectors.v1.json New shared conformance vectors (v1).
contracts/README.md Documents ownership boundary, hooks, conformance vocabulary, and versioning expectations.
contracts/fixtures/reference.js Native-first progressive-enhancement reference behaviors (tabs, tooltip, copy, theme, mobile nav, dialog).
contracts/fixtures/reference.html Plain HTML reference surface demonstrating the primitives and hooks without React/Tailwind.
contracts/CHANGELOG.md Changelog entry for v1.0.0 contract release.
.prettierignore Excludes contracts/ from Prettier formatting.
Files not reviewed (1)
  • contracts/fixtures/reference.js: Generated file
Suppressed comments (1)

scripts/verify-contracts.mjs:213

  • Similarly, disclosure is excluded from the reference fixture coverage check. If disclosure is one of the published primitives, the reference fixture should include a data-oc-primitive="disclosure" example (or disclosure should be removed from the required list).
for (const id of requiredPrimitives.filter((id) => id !== "disclosure")) {
  requirePortable(
    fixture.includes(`data-oc-primitive="${id}"`),
    `reference fixture is missing ${id}`,
  );
}

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +152 to +155
requirePortable(
portable.global?.targetMinimumCssPx?.every((value) => value >= 44),
"target minimum must be 44×44 CSS px",
);
Comment thread scripts/verify-contracts.mjs Outdated
Comment on lines +201 to +206
for (const mode of ["no-js", "reduced-motion", "forced-colors", "320px", "200%-zoom"]) {
requirePortable(
vectors.vectors.some((vector) => vector.modes.includes(mode)),
`no vector covers ${mode}`,
);
}
Comment thread scripts/verify-contracts.mjs Outdated
Comment on lines +197 to +200
requirePortable(vectorIds.size >= 24, "at least 24 shared vectors are required");
for (const id of requiredPrimitives.filter((id) => id !== "disclosure")) {
requirePortable(covered.has(id), `no vector covers ${id}`);
}
@BunsDev
BunsDev merged commit ada9fe4 into main Aug 31, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[P1][Landing vNext] Publish framework-neutral interaction contracts and accessibility test vectors

2 participants